<?php

namespace App;

use Illuminate\Database\Eloquent\Model;

/**
 * App\Device
 *
 * @property int $id
 * @property int|null $apply_id
 * @property string|null $comment
 * @property int|null $device_id
 * @property int|null $major
 * @property int|null $minor
 * @property int|null $status
 * @property string|null $last_active_time
 * @property int|null $poi_id
 * @property string|null $uuid
 * @property \Carbon\Carbon|null $created_at
 * @property \Carbon\Carbon|null $updated_at
 * @property int|null $page_id
 * @property-read \App\Http\Controllers\Admin\Scene\Repository\Spot $spot
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereApplyId($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereComment($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereCreatedAt($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereDeviceId($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereId($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereLastActiveTime($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereMajor($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereMinor($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device wherePageId($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device wherePoiId($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereStatus($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereUpdatedAt($value)
 * @method static \Illuminate\Database\Eloquent\Builder|\App\Device whereUuid($value)
 * @mixin \Eloquent
 */
class Device extends Model
{
    protected $fillable=['apply_id','comment','device_id','major','minor','status','last_active_time','poi_Id','uuid'];
    public function spot(){
        return $this->hasOne('App\Http\Controllers\Admin\Scene\Repository\Spot','page_id','page_id');
    }
}
